package com.zhang.dft_project.controller;

import com.zhang.dft_project.common.R;
import com.zhang.dft_project.vo.req.UserReq;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 操作员管理
 */
@RestController
public class OperatorController {


    @GetMapping("/operator/login")
    public R login(@Validated UserReq userReq){
        if ("root".equals(userReq.getUsername()) && "1234567".equals(userReq.getPassword())) {
            return new R(200,"登录成功","登陆成功");
        }
        return new R(603,"登录失败");
    }
}
